package org.shj.pattern.simplefactory;

class CashRebate extends Cash{
	
	private double rebate = 1d;
	
	public CashRebate(double rebate){
		this.rebate = rebate; //打折收费，需要传入折扣
	}

	@Override
	public double acceptCash(double money) {
		return money * rebate;
	}

}
